﻿
using System;

namespace GFramework
{
    /// <summary>
    /// 叶子
    /// </summary>
    public abstract class Leaf : IReference, IDisposable
    {
        virtual public Composite Parent { get; set; }

        virtual public int ID
        {
            get
            {
                return 0;
            }
        }

        virtual public void Clear()
        {

        }

        public void Dispose()
        {
            CompositeFactory.Destory(this);
        }
    }
}
